package edu.sctu.practice.class01.wangxiaoqiang.assgin2;

/**
 * Created by admin on 2015/10/8.
 */
public class Client {
    public static void main(String[] args) {

        Circle circle = new Circle(3);
        circle.getArea();
        ShowMessage showMessage = new ShowMessage();
        showMessage.printCircle(circle);

        Circle circleOne = new Circle(2);
        circleOne.getArea();
        ShowMessage showMessageOne = new ShowMessage();
        showMessageOne.printCircle(circleOne);

        System.out.println("");

        Rational rational = new Rational(2, 4);
        System.out.println("加法执行的结果是" + rational.add());
        System.out.println("减法执行的结果是" + rational.sub());
        System.out.println("乘法执行的结果是" + rational.mul());
        System.out.println("除法执行的结果是" + rational.div());

        System.out.println("");

        Rational rat = new Rational(2, 0);
        System.out.println("加法执行的结果是" + rat.add());
        System.out.println("减法执行的结果是" + rat.sub());
        System.out.println("乘法执行的结果是" + rat.mul());
        System.out.println("除法执行的结果是" + rat.div());

        Circle.getNumOfObjects();


    }

}
